import config from '@/utils/config';
import { MockMethod } from 'vite-plugin-mock';

export default [
  {
    url: config.url.home,
    method: 'get',
    response: () => {
      return {
        code: 200,
        data: {
          carousel: [
            {
              id: 1,
              name: 'A',
              img: 'https://m15.360buyimg.com/mobilecms/jfs/t1/74351/17/23078/101563/63e2ff77Fe2a9fe9c/651f8bb7149cf216.jpg!cr_1125x449_0_166!q70.jpg',
              url: '/pages/goods/goods',
              type: 'carousel',
              remark: '',
            },
            {
              id: 2,
              name: 'B',
              img: 'https://imgcps.jd.com/img-cubic/creative_server_cia_jdcloud/v2/2000268/100029662810/FocusFullshop/CkFqZnMvdDEvMjI0MTE2LzYvNDgxMi8zNzYyMi82NTYyNGY4YUY1MGM0YzIxNy9jYzk2NzJiZGU0ZGNiYzNmLnBuZxILNTE2LXR5XzBfODgwATiMi3pCFgoS5rW35L-h55S154Ot5rC05ZmoEAFCEAoM55ub5oOg54us5LqrEAJCEAoM56uL5Y2z5oqi6LStEAZCCgoG5LyY6YCJEAdY2ozu0fQC/cr_1125x449_0_166/s/q70.jpg',
              url: '/pages/goods/goods',
              type: 'carousel',
              remark: '',
            },
            {
              id: 3,
              name: 'C',
              img: 'https://imgcps.jd.com/ling4/10066482065481/5aS55YWL5oqY5omj6ZKc5oOg/5pS-5b-D5peg5b-n6LSt/p-60541365d250103053e030ee/0b03a05d/cr_1125x449_0_166/s/q70.jpg',
              url: '/pages/goods/goods',
              type: 'carousel',
              remark: '',
            },
            {
              id: 4,
              name: 'D',
              img: 'https://m15.360buyimg.com/mobilecms/s1062x420_jfs/t1/184134/9/32429/81116/64015babF0a8679cb/1fb03ec240db83be.jpg!cr_1053x420_4_0!q70.jpg',
              url: '/pages/goods/goods',
              type: 'carousel',
              remark: '',
            },
            {
              id: 5,
              name: 'E',
              img: 'https://m15.360buyimg.com/mobilecms/s1062x420_jfs/t1/189579/6/33537/59485/6406e94cFf4985306/306696e1f4ae1d50.jpg!cr_1053x420_4_0!q70.jpg',
              url: '/pages/goods/goods',
              type: 'carousel',
              remark: '',
            },
          ],
          category: [
            {
              id: 1,
              name: '手机',
              img: '//gw.alicdn.com/imgextra/i4/O1CN01XCiY1B1px9ivHkDGm_!!6000000005426-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 2,
              name: '电脑',
              img: '//gw.alicdn.com/imgextra/i1/O1CN018Ilnep1Qt9ryh1Vue_!!6000000002033-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 3,
              name: '平板',
              img: '//gw.alicdn.com/imgextra/i3/O1CN01FgQFp81spmBXqQMtA_!!6000000005816-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 4,
              name: '服饰',
              img: '//gw.alicdn.com/imgextra/i2/O1CN01gUIFrA1OuPj70aTIW_!!6000000001765-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 5,
              name: '家电',
              img: '//gw.alicdn.com/imgextra/i1/O1CN01tsk5OY1q0MUo5PJga_!!6000000005433-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 6,
              name: '摄影',
              img: '//gw.alicdn.com/imgextra/i3/O1CN013WcsZW1jfr4AXnmVl_!!6000000004576-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 7,
              name: '鞋子',
              img: '//gw.alicdn.com/imgextra/i2/O1CN01yK3Cxn1sTnAx1fOjq_!!6000000005768-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 8,
              name: '会员',
              img: '//gw.alicdn.com/imgextra/i2/O1CN01ZOR1cv1yjGFORGh1V_!!6000000006614-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 9,
              name: '包包',
              img: '//gw.alicdn.com/imgextra/i1/O1CN01iZIGkz1URSOUdRHqS_!!6000000002514-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 10,
              name: '网络',
              img: '//gw.alicdn.com/tfs/TB1WgOmesieb18jSZFvXXaI3FXa-183-144.png_q90.jpg_.webp?getAvatar=1',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 11,
              name: '耳机',
              img: '//gw.alicdn.com/imgextra/i4/O1CN01VuRfwH1muSbsJFxoM_!!6000000005014-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 12,
              name: '耳机',
              img: '//gw.alicdn.com/imgextra/i1/O1CN01rIm4u11F81KogrKz4_!!6000000000441-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
            {
              id: 13,
              name: '耳机',
              img: '//gw.alicdn.com/imgextra/i2/O1CN01qrrUAN1wRjrhtfk6Q_!!6000000006305-2-tps-183-144.png_q90.jpg_.webp',
              type: 'category',
              url: '/pages/goods/goods-list',
              remark: '',
            },
          ],
          limit: {
            title: '限时秒杀',
            time: 16,
            type: '0',
            data: [
              {
                id: 1,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/166006/39/18916/513976/6079653bEe766e8e1/49efc9d0015ec241.png',
                price: 10880,
              },
              {
                id: 2,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/171580/23/35916/53051/6412e36aF2062f90e/5c1fd66596ff2218.jpg',
                price: 139900,
              },
              {
                id: 3,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/82306/35/22592/49048/6385c0fcE77691026/62c7e183f5364e55.jpg',
                price: 201800,
              },
              {
                id: 4,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/9701/14/21055/103030/63a84e67Ebdba6f42/b8c6067ad24c2248.jpg',
                price: 1700,
              },
              {
                id: 5,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/184440/35/30792/107915/638eef5fE718bd12f/af6c08dc2ae75fde.jpg',
                price: 46000,
              },
              {
                id: 6,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/152723/20/31044/144353/6417b791Fd40aa966/4c5faba6baa805ee.jpg',
                price: 17990,
              },
              {
                id: 7,
                name: '',
                img: '//m.360buyimg.com/seckillcms/jfs/t1/68445/16/24639/166662/6417c36eF24131397/eeb42677c0c4c696.jpg',
                price: 2488,
              },
            ],
          },
        },
        message: 'success',
      };
    },
  },
] as MockMethod[]; // 这里其实就是定义数据格式的，不了解的同学可以参考typescript的官方文档
